from tkinter import *
def hello():
     global count, i
     color = ['gray', 'black', 'white']
     btn['bg'] = color[i]
     i+=1
     if i == 3:
          i = 0
     count+=1
     print(count, i)
win = Tk()
count= 0
i = 0
btn = Button(text = 'Hello', bg = 'gray', width = 10, height = 5, command = hello)
btn.pack()
win.mainloop()
#1001100010001
#125147061
#CA8A856
#10279FF2C
